package com.silas.dynflightdatatransfer.enums;

public enum RespEnum {

    //Config Error 1xxx  基础配置异常
    SYSTEM_ERROR(1000, "系统错误"),
    DATABASE_ERROR(1001, "数据库异常"),
    CONNECTION_ERROR(1002, "网络连接请求失败"),

    //Success 2xxx  业务逻辑成功
    /**
     * 特定使用,谨慎修改
     */
    OPERATE_SUCCESS(2003, "操作成功"),
    UPLOAD_FILE_SUCCESS(2006, "上传成功"),
    QUERY_SUCCESS(2007, "查询成功"),

    //Error 3xxx  业务逻辑失败
    OPERATE_FAILURE(3000, "操作失败"),
    /**
     * 特定使用,谨慎修改
     */
    OPERATE_REPEAT(3001, "操作频繁，请稍后再试"),
    /**
     * 特定使用,谨慎修改
     */
    NO_LOGIN(3004, "用户未登录"),
    NO_RECORD(3007, "没有找到相关记录"),
    INVALID_MOBILE(3010, "无效的手机号码"),
    INVALID_EMAIL(3011, "无效的邮箱"),
    INVALID_FILE(3012, "无效的文件"),
    BAD_FILE_TYPE(3016, "文件类型不支持"),
    FILE_SIZE_EXCEED(3017, "文件大小超限"),
    APPLY_STATE_ERROR(3019, "当前状态不支持操作"),
    SUBMIT_REPEAT_ERROR(3020, "请勿重复提交，请稍后再试"),
    FLIGHT_TIME_EMPTY(3021, "申请飞行【开始时间】和【结束时间】不能为空"),
    FLIGHT_END_TIME_ERROR(3022, "申请飞行【结束时间】不能早于当前时间"),
    FLIGHT_START_END_TIME_ERROR(3023, "申请飞行【结束时间】不能早于【开始时间】"),
    COMPANY_BUSINESS_LICENSE_FILES_EMPTY(3024, "请先上传【企业营业执照】"),
    ID_POSITIVE_FILES_EMPTY(3025, "请先上传【身份证正面照片】"),
    ID_NEGATIVE_FILES_EMPTY(3026, "请先上传【身份证反面照片】"),
    COMPANY_BUSINESS_LICENSE_FILE_TYPE_ERROR(3027, "请上传正确的【企业营业执照】，支持文档（pdf）或图片（jpg、jpeg、png）"),
    ID_POSITIVE_FILE_TYPE_ERROR(3028, "请上传正确的【身份证正面照片】，支持图片（jpg、jpeg、png）"),
    ID_NEGATIVE_FILE_TYPE_ERROR(3029, "请上传正确的【身份证反面照片】，支持图片（jpg、jpeg、png）"),
    UAV_FILE_TYPE_ERROR(3030, "请上传正确的【无人机照片】，支持图片（jpg、jpeg、png）"),
    UPLOAD_FILE_ERROR(3031, "文件上传失败"),
    DOWNLOAD_ERROR(3032, "文件下载失败"),
    PDF_CREATE_ERROR(3033, "生成pdf文件失败"),
    XML_CREATE_ERROR(3034, "生成xml文件失败"),
    UAV_PHOTO_FILES_EMPTY(3035, "请先上传【无人机照片】"),
    FLIGHT_PLAN_FILES_EMPTY(3036, "请先上传【飞行许可文件】"),
    FLIGHT_PLAN_FILE_TYPE_ERROR(3037, "请上传正确的【飞行许可文件】，支持文档（pdf）或图片（jpg、jpeg、png）"),
    FILE_SUM_ERROR(3038, "上传文件个数超限，请重新提交"),
    LEGAL_ID_NEGATIVE_EMPTY(3039, "请先上传【法人身份证反面照片】"),
    LEGAL_ID_POSITIVE_ERROR(3040, "请先上传【法人身份证正面照片】"),
    NOT_CRIME_FILE_TYPE_ERROR(3041, "请上传正确的【无犯罪记录证明】，支持文档（pdf）或图片（jpg、jpeg、png）"),
    FLIGHT_LICENSE_FILE_TYPE_ERROR(3042, "请上传正确的【飞行许可文件】，支持文档（pdf）或图片（jpg、jpeg、png）"),
    PERSON_NAME_EMPTY(3043, "请填写个人姓名"),
    PERSON_PHONE_EMPTY(3044, "请填写个人手机号"),
    PERSON_EMAIL_EMPTY(3045, "请填写个人邮箱"),
    PERSON_ID_NO_EMPTY(3046, "请填写个人证件号码"),
    COMPANY_NAME_EMPTY(3047, "请填写企业名称"),
    COMPANY_TYPE_EMPTY(3048, "请填写企业类型"),
    COMPANY_ADDR_EMPTY(3049, "请填写企业注册地址"),
    COMPANY_BUSINESS_LICENSE_CODE_EMPTY(3050, "请填写企业统一社会信用代码或注册号"),
    COMPANY_LEGAL_NAME_EMPTY(3051, "请填写企业法人名称"),
    COMPANY_LEGAL_PHONE_EMPTY(3052, "请填写企业法人手机号"),
    COMPANY_LEGAL_ID_NO_EMPTY(3053, "请填写企业法人证件号码"),
    NOT_CRIME_FILE_EMPTY(3054, "请先上传飞手【无犯罪记录证明】"),
    SERIAL_NO_ERROR(3055, "申请编号生成失败，请稍后重试"),
    APPLY_PERSON_EMPTY(3056, "申请人信息为空"),
    FLYER_EMPTY(3057, "飞手信息为空"),
    APPLY_PERSON_SAVE_ERROR(3059, "保存申请人信息失败"),
    APPLY_CANCEL_STATE_ERROR(3060, "取消中或已取消状态，不可操作"),
    SIZE_LIMIT_ERROR(3061, "文件大小超过限制"),
    AIRSPACE_APPLY_TIME_ERROR(3062, "【非紧急任务】需提前5天进行申请"),
    COMPANY_CONTACT_NAME_EMPTY(3063, "请填写企业联系人"),
    COMPANY_CONTACT_PHONE_EMPTY(3064, "请填写企业联系人手机号"),
    COMPANY_BUSINESS_SCOPE_EMPTY(3065, "请填写企业主要经营范围"),
    UAV_EMPTY_WEIGHT_RANGE_ERROR(3066, "请输入正确的无人机空机重量"),
    UAV_FLIGHT_WEIGHT_RANGE_ERROR(3067, "请输入正确的无人机最大起飞重量"),
    UPLOAD_EXCEL_FILE_ERROR(3071, "请上传正确的Excel文件（xls、xlsx）"),
    /**
     * 特定使用,谨慎修改
     */
    READ_EXCEL_FAIL_ERROR(3072, "读取Excel文件数据失败"),
    READ_EXCEL_FILE_TOTAL_ROW_ERROR(3073, "Excel文件总行数超出限制"),
    READ_EXCEL_DATA_VALID_EMPTY(3080, "没有读取到有效的数据，请检查后再重新上传"),

    //Client Error 4xxx  客户端错误  仿照4xx的http错误
    BAD_REQUEST(4000, "请求参数错误"),
    UNAUTHORIZED(4001, "未经授权"),
    PAYMENT_REQUIRED(4002, "付费请求"),
    FORBIDDEN(4003, "资源不可用"),
    NOT_FOUND(4004, "无效的访问路径"),
    METHOD_NOT_ALLOWED(4005, "不合法的请求方式"),
    NOT_ACCEPTABLE(4006, "不可接受"),
    PROXY_AUTHENTICATION_REQUIRED(4007, "需要代理身份验证"),
    REQUEST_TIMEOUT(4008, "请求超时"),
    CONFLICT(4009, "指令冲突"),
    GONE(4010, "文档永久地离开了指定的位置"),
    LENGTH_REQUIRED(4011, "需要CONTENT-LENGTH头请求"),
    PRECONDITION_FAILED(4012, "前提条件失败"),
    REQUEST_ENTITY_TOO_LARGE(4013, "请求实体太大"),
    REQUEST_URI_TOO_LONG(4014, "请求URI太长"),
    UNSUPPORTED_MEDIA_TYPE(4015, "不支持的媒体类型"),
    REQUESTED_RANGE_NOT_SATISFIABLE(4016, "请求的范围不可满足"),
    EXPECTATION_FAILED(4017, "期望失败"),


    //Server Error 5xxx  服务器错误  仿照5xx的http错误
    INTERNAL_SERVER_ERROR(5000, "内部服务器错误"),
    NOT_IMPLEMENTED(5001, "未实现"),
    BAD_GATEWAY(5002, "错误的网关"),
    SERVICE_UNAVAILABLE(5003, "服务不可用"),
    GATEWAY_TIMEOUT(5004, "网关超时"),
    HTTP_VERSION_NOT_SUPPORTED(5005, "HTTP版本不支持"),


    //终极赖皮手段
    UNKNOWN_ERROR(0000, "未知错误");

    private Integer code;
    private String msg;

    private RespEnum(Integer code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public Integer getCode() {
        return code;
    }

    public void setCode(Integer code) {
        this.code = code;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }
}
